package com.baidu.file;

import java.io.File;

public class D03_FileCreate {
    public static void main(String[] args) {
        File file = new File("src/data");

        //创建目录或者文件
        if(!file.exists()){
            //单级创建
            boolean mkdir = file.mkdirs();
            System.out.println(mkdir);
        }

        /**
        //删除
        //不能删除非空文件夹
        if(file.exists()){
            boolean delete = file.delete();
            System.out.println(delete);
        }
         */
    }
}
